﻿using log4net;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

//注意下面的语句一定要加上，指定log4net使用.config文件来读取配置信息
[assembly: log4net.Config.XmlConfigurator(Watch = true, ConfigFile = "log4net.config")]
namespace AuthTemplate.Infrastructure
{
    public class LogHelper
    {
        public static readonly ILog _log = LogManager.GetLogger("logerror");

        public static void Log(string message)
        {
            _log.Info(message);
        }

        public static void Debug(string message)
        {
            _log.Debug(message);
        }

        public static void Error(string message)
        {
            _log.Error(message);
        }

        public static void Warn(string message)
        {
            _log.Warn(message);
        }
    }
}
